package cn.biao.epic.sys.core.auth.userdetail;

import cn.biao.epic.base.auth.service.AuthService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.security.core.userdetails.UserDetails;
import org.springframework.security.core.userdetails.UserDetailsService;
import org.springframework.security.core.userdetails.UsernameNotFoundException;

/**
 * @Auther Uncle_Z
 * @date 2019/12/16 16:06
 * @Email:2545375@qq.com
 * @Descrition
 */
public class JwtUserDetailsServiceImpl implements UserDetailsService {

    @Autowired
    private AuthService authService;

    @Override
    public UserDetails loadUserByUsername(String s) throws UsernameNotFoundException {
        return authService.user(s);
    }
}
